package com.tcs.test.designmodel.abstactfactory;

/**
 * @ClassName : ColorFactory
 * @Author : 神经刀
 * @Date : 2019/5/29 : 9:10
 * @Version : 1.0
 */
public class ColorFactory extends AbstactCoulorFactory {

    @Override
    public Colour gerColor(String colour) {
        Colour colour1 = null;
        if (colour.equals("bule")) {
            colour1 = new Blue();
        } else if (colour.equals("red")) {
            colour1 = new Red();
        }
        return colour1;
    }
}
